#dockerfile.htpasswd.sh

FROM alpine:3.12

RUN date && \
    sed -i 's/dl.*org/mirrors.aliyun.com/g' /etc/apk/repositories && \
    apk add --update apache2-utils && \
    rm -rf /var/cache/apk/*

ENTRYPOINT ["htpasswd", "-Bbn"]


##########
#docker build --no-cache -t alivv/htpasswd -f dockerfile.htpasswd.sh .

#创建密码文件
#docker run --rm alivv/htpasswd user password >htpasswd

# registry.aliyuncs.com/elvin/htpasswd
